function func(x) {
  x /= 57.2;
  return Math.sin(x) *40;
}
function generateData() {
  let data = [];
  for (let i = 0; i <= 720; i += 1) {
    data.push([i, func(i)]);
  }
  return data;
}
option = {
  animation: false,
  grid: {
    top: 40,
    left: 50,
    right: 40,
    bottom: 50
  },
  xAxis: {
    type: 'value',
    name: 't',
    interval: 90,  //坐标轴刻度标签的显示间隔
    min: 0,
    max: 720,
  },
  yAxis: {
    type: 'value',
    name: 'load',
    min: -70, // 最小值
    max: 70,
    interval: 40,
  },
  series: [
    {
      type: 'line',
      showSymbol: false,
      clip: true,
      data: generateData()
    }
  ]
};
